{% extends "base.html" %}

{% block body_page %}
<script type="text/javascript">
var d=new Date()
$(document).ready(function(e) {
    $('#getauth').change(function(){
		$.get("getauth/?u="+$(this).find(':selected').val()+"&t="+d.getTime(),function(result){
			$("#authbox").html(result);
	    });
		
	})
});
</script>

<div class="list">
    <div class="line">
        <form  action="http://{{domain}}/index/global_set/webinfo/" method="get" enctype="application/x-www-form-urlencoded" name="form1">
           <p>本站全局设置
           </p><p>域名
           <input type="text" name="textfield" id="textfield" value ="{{domain}}">
           <label for="textfield2"></label>
           <label>本站 Title </label><input type="text" name="textfield2" id="textfie2" value="{{title}}">
           <input type="submit" name="button" id="button" value="提交">
           </p>
        </form>
        <!--div line -->
        </div>
       <div class="line">
       <form  action="http://{{domain}}/index/global_set/adduser/" method="get" enctype="application/x-www-form-urlencoded" name="form2">
       <p>添加用户</p>
       <p>添用户名
         <label for="textfield3"></label>
         <input type="text" name="textfield3" id="textfield3">
         设置密码
         <label for="textfield4"></label>
         <input type="password" name="textfield4" id="textfield4">
         用户邮箱
         <label for="textfield5"></label>
         <input type="text" name="textfield5" id="textfield5">
         <input type="submit" name="button2" id="button2" value="提交">
       </p>
       </form>
    <!--div line -->
    </div>
    <div class="line">
        <table width="100%" border="0"> 
            <tr>
                <td style="border-right:solid 1px #add9c0;" width="45%">
		  <form action="http://{{domain}}/index/global_set/initpasswd/" method="get" enctype="application/x-www-form-urlencoded" name="form31" id="form31">
			<p><label>恢复用户默认密（默认密码为1234567）</label>
			<p>
			  <label>用户名</label>
			  <select name="u31" id="u31">
				  <option >当前用户列表</option>
				  {% for user in users %}
				  <option >{{escape(user.user)}}</option>
				  {% end %}
			  </select>
			  <input type="submit" name="button" id="button" value="提交" />
                         </p>
                   </form>
                </td>
                <td style="border-left:solid 1px black;">
                  <form action="http://{{domain}}/index/global_set/disbleuser/" method="get" enctype="application/x-www-form-urlencoded" name="form32" id="form32">
                        <p><label>禁用账户。如要启动账户，对其初始密码即可。</label>
                        <p>
                          <label>用户名</label>
                          <select name="u32" id="u32">
                                  <option >当前用户列表</option>
                                  {% for user in users %}
                                  <option >{{escape(user.user)}}</option>
                                  {% end %}
                          </select>
                          <input type="submit" name="button" id="button" value="提交" />
                         </p>
                   </form>
                </td>
             </tr>
         </table>
    <!-- div line-->
    </div>
    <div class="line">
        <form action="http://{{domain}}/index/global_set/addproject/" method="get" enctype="application/x-www-form-urlencoded" name="form1" id="form1">
          <p><label>新建项目</label>
            （项目名为字母和数字不能包含特殊符号）</p>
          <p>
            <label>项目名</label>
            <label for="textfield_pro"></label>
            <input type="text" name="textfield_pro1" id="textfield_pro1" />
            <label>备注(限100字)</label>
            <label for="textfield_pro2"></label>
            <input type="text" name="textfield_pro2" id="textfield_pro2" />
            <input type="submit" name="button" id="button" value="提交" />
          </p>
        </form>
     <!--- dive line -->
    </div>
    <div class="line">
    <form id="form3" name="form3" method="get" action="http://{{domain}}/index/global_set/editauth/" enctype="application/x-www-form-urlencoded">
      <p>修改用户权限
      </p>
      <p>
        <label for="select"></label>
        <select name="u" id="getauth">
              <option >当前用户列表</option>
              {% for user in users %}
                    <option >{{escape(user.user)}}</option>
              {% end %}
        </select>
        <input type="submit" name="button3" id="button3" value="提交">
      <div id="authbox">
      </div>
    </form>
    </p>
  <!--line--></div>
<!--div list  -->
</div>
{% end %}

